#!/Library/Frameworks/Python.framework/Versions/Current/bin/python

import wx
import math

class MainPanel(wx.Panel):

	def __init__(me,parent):
		wx.Panel.__init__(me,parent)
		me.Bind(wx.EVT_PAINT, me.OnPaint)

	def OnPaint(me, evt):
		dc = wx.PaintDC(me)
		gc=wx.GraphicsContext.Create(dc)
		
		p=gc.CreatePath()
		p.AddRoundedRectangle(0,0,30,100,4)
		
		br=gc.CreateLinearGradientBrush(0,0,30,0,wx.RED, wx.BLUE)
		gc.SetBrush(br)
		gc.Rotate(180./math.pi)
		for i in range(10):
			gc.Translate(35,0)
			gc.DrawPath(p)
		
class MainFrame(wx.Frame):

	def __init__(me):
			
		wx.Frame.__init__(me,parent=None)
		MainPanel(parent=me)
		

app = wx.PySimpleApp()
frame = MainFrame()
frame.Show()
frame.Centre()
app.MainLoop()